/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.ufpb.halloc.dados;

/**
 *
 * @author Filipe
 */
public abstract class CentroDAOFactory{

    public static final int BD = 1;
    public static final int FILE = 2;

    public abstract CentroDAO getCentroDAO(int tipo);

    public static CentroDAOFactory getCentroDAOFactory(int tipoPersistencia) {

        switch (tipoPersistencia) {
            case BD:
                return CentroDAOBDFactory.getInstance();
            case FILE:
                return CentroDAOArquivoFactory.getInstance();
            default:
                return null;
        }
    }
}
